/**前端用户存在验证  check-user='提示信息（用户不存在）'**/
yjx.directive('checkUser',['$rootScope','$timeout','ipCookie','$init','LoginService','$location',
    function($rootScope,$timeout,ipCookie,$init,LoginService,$location){
        return {
            restrict:'EA',
            priority : 1,
            scope:true,
            link:function($scope,$elem,attr){
                //alert(ipCookie('Uid'))
                //alert($rootScope.userId)
                    if ($rootScope.userId){

                    }else {
                        //调用微信登录
                        //alert($location.url());
                        LoginService.wxAutoLogin($location.url());
                    }
            }
        }
    }])